The present invention relates generally to an updating of a software module in a layered filesystem.
A given software product may be provided to a user in a software package that is typically built and managed using a software package manager. In this document, a software package manager (or “software package management system”) is defined as any collection of software tools that automate the process of installing, upgrading, configuring, and removing computer programs for a computer's operating system in a consistent manner. A software package manager typically deals with packages, distributions of software and data in archive files. Software packages typically include metadata, such as the software's name, description of its purpose, version number, vendor, checksum, and a list of dependencies necessary for the software to run properly. Upon installation, metadata is typically stored in a local package database. Software package managers typically maintain a database of software dependencies and version information to prevent software mismatches and missing prerequisites. Software package managers typically work closely with software repositories, binary repository managers, and app stores. Software package managers are typically designed to eliminate the need for manual installs and updates, which can be particularly useful for large enterprises whose operating systems are based on Linux and other Unix-like systems, typically consisting of hundreds or even tens of thousands of distinct software packages.
A software product typically includes a software application that is made up of a relatively large number of “software modules.” Each software module typically defines a given function (or set of functions) that is needed for running the software application on a data processor/computing system. Such a software module is compiled as code defining a set of instructions, which when executed by a data processor/computing system, causes the given function(s) associated with that software module to be performed by a computing device.
A software module may be provided as a part of a given software library stored in an online repository that is accessible to a user of the software package in which the software module is encapsulated. Software modules are changed by their developers relatively regularly in that they may, for example, be updated according to any modified functionality that they define in respect of a given software application and/or to fix any bugs reported in respect of their use. Given that software applications also undergo further development, relatively large dependency chains of software modules are typically formed and typically accumulate as this further development proceeds over time. This is especially true with high-level, interpreted programming languages that are dynamic, weakly typed, prototype-based and multi-paradigm (such as Javascript and package managers for Javascript).
In the specific case of a Node.js application to be run on a given data processor/computing system, it is installed and managed with an NPM (sometimes also referred to as “npm”) package manager. An npm install command installs the dependency chains of software modules that are required for running the Node.js application on the processor/system. This is done by accessing a package.json file, which describes certain aspects of the Node.js application and also what dependency chains of corresponding software modules need to be installed for running the Node.js application. Apart from the installation and management of the Node.js application, an appropriate environment is required for running it. For example, this is conventionally sometimes done by using Docker container technology, specifically by accessing a given Docker file, which contains instructions on commands to run in order to create an appropriate system for running the Node.js application.
With respect to Docker containerization, it uses a layered filesystem to install layers including dependency chains of given software modules encapsulated in the Node.js application. The layers of a given Docker file are accessed/installed on a line-by-line basis to deploy the Node.js application on a given processor/system. The layers are rebuilt and re-installed when an associated change occurs in respect of the software modules required for running the Node.js application, in their corresponding dependency chains. For example, an npm install command would install the entire dependency chain of a layer in the Docker file, even if only a part of that dependency chain was updated/modified in the package.json file.